var util = require('../../../utils/util.js');
var api = require('../../../config/api.js');

Page({
  data:{
    assessList: [],
  },
  onLoad:function(options){
    // 页面初始化 options为页面跳转所带来的参数
    wx.setNavigationBarTitle({
      title: "订单评价"
    })
    this.getAssessList();
  },
  getAssessList(){
    let that = this;
    let user_id = wx.getStorageSync('userId');
    let userdata = { user_id: user_id};
    util.request(api.assessList,userdata).then(function (res) {
      if (res.errno == 0) {
        that.setData({
          assessList:res.data,
        })
        wx.hideLoading();
      }
    });
  },
  onReady:function(){
    // 页面渲染完成
  },
  onShow:function(){
    // 页面显示
  },
  onHide:function(){
    // 页面隐藏
  },
  onUnload:function(){
    // 页面关闭
  }
})